package week2;
import java.util.Arrays;
public class ArraySortAndSearch {
    public static void main(String[]args){
        int[]arr={25,63,54,91,14,5,17,25,88,32,44};
        Arrays.sort(arr);
        int index14 =Arrays.binarySearch(arr,14);
        int index88 =Arrays.binarySearch(arr,88);
        System.out.println("排序后数组:"+Arrays.toString(arr));
        System.out.println("元素14的索引："+index14);
        System.out.println("元素88的索引："+index88);
    }
}
